// 物料搜索参数
export interface MaterialSearch {
  index: number;
  pageSize: number;
  key?: string;
  status?: boolean;
  isVulnerable?: boolean;
  materialCategoryId?: string;
  materialName?: string;
  materialCode?: string;
}

// 物料输入DTO
export interface MaterialInput {
  materialCode: string;
  materialName: string;
  materialCategoryId?: string;
  unit?: string;
  specification?: string;
  image?: string;
  isVulnerable: boolean;
  replacementCycle?: number;
  productionPrice?: number;
  salePrice?: number;
  tradeInPrice?: number;
  status: boolean;
}

// 物料输出DTO
export interface MaterialOut {
  id: string;
  materialCode: string;
  materialName: string;
  materialCategoryId?: string;
  unit?: string;
  specification?: string;
  image?: string;
  isVulnerable: boolean;
  replacementCycle?: number;
  productionPrice?: number;
  salePrice?: number;
  tradeInPrice?: number;
  status: boolean;
  creatTime: string;
  updateTime?: string;
}

// 物料搜索结果
export interface MaterialSearchOut {
  totalCount: number;
  items: MaterialOut[];
}

// 产品物料关联输入
export interface ProductMaterialInput {
  productId: string;
  materialId: string;
  quantity: number;
}

// 产品物料关联输出
export interface ProductMaterialOut {
  id: string;
  productId: string;
  materialId: string;
  quantity: number;
  material: MaterialOut;
}

// 物料分类搜索参数
export interface MaterialCategorySearch {
  index: number;
  pageSize: number;
  key?: string;
  statue?: boolean;
}

// 物料分类输入DTO
export interface MaterialCategoryInput {
  name: string;
  code: string;
  description?: string;
  statue: boolean;
  parentId?: string;
  sort?: number;
}

// 物料分类输出DTO
export interface MaterialCategoryOut {
  id: string;
  name: string;
  code: string;
  description?: string;
  statue: boolean;
  parentId?: string;
  level: number;
  sort: number;
  creatTime: string;
  updateTime?: string;
  children?: MaterialCategoryOut[];
}

// 物料分类搜索结果
export interface MaterialCategorySearchOut {
  totalCount: number;
  items: MaterialCategoryOut[];
} 